<!doctype html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <title>Laravel</title>

        <!-- Fonts -->
        <link href="https://fonts.googleapis.com/css?family=Nunito:200,600" rel="stylesheet">

    </head>
    <body>
        <form action="{{url('admin/machine_good')}}" method="post">
            <input type="hidden" name="_token" value="{{ csrf_token() }}">
            <input type="hidden" name="machine_id" value="{{ $id }}">
            @foreach ($goods as $k=>$good)
              <p>{{$good['name']}}<input type="hidden" name = good_id[] value={{$good['id']}}><span style="margin-left:30px">产品数量：<input type="text" name = stock[] value={{$good['stock']}}></span></p>
            @endforeach
            <input type="submit"/>
        </form>
    </body>
</html>
